#include <gtest/gtest.h>
#include "../core/WordReport.h"

TEST(TextReportTest, Calculate) {
    TextReport report;

    std::vector<std::string> words = {"apple", "banana", "cherry", "date", "elderberry"};

    report.Calculate(words);

    // Verify the summary
    std::string expectedSummary = "Total number of words: 5\nThe number of words started with char 'a': 2\nThe number of words started with char 'b': 1\nThe number of words started with char 'c': 1\nThe number of words started with char 'd': 1\nThe number of words started with char 'e': 1\n=========================\napple banana cherry date elderberry ";
    EXPECT_EQ(report.GetSummary(), expectedSummary);
}
